<?php

use yii\db\Migration;

/**
 * import init data
 */
class m210905_181300_news extends Migration
{

    /**
     * @return bool|void
     */
    public function down()
    {
        $this->dropColumn('{{%news}}', 'image');
    }

    /**
     * @return bool|void
     */
    public function up()
    {
        $this->addColumn('{{%news}}', 'image', $this->string()->notNull()->defaultValue('')->comment('图片')->after('title'));
    }
}
